package com.leicx.guli.product.feign.fallback;

import com.leicx.guli.common.enums.BizCodeEnum;
import com.leicx.guli.common.utils.R;
import com.leicx.guli.product.feign.SeckillFeignService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

/**
 * @author daxiong
 * @date 2022/8/21 下午9:54
 */
@Component
@Slf4j
public class SeckillFeignServiceFallback implements SeckillFeignService {
    @Override
    public R getSkuSeckillInfo(Long skuId) {
        log.info("====熔断方法执行... getSkuSeckillInfo()");
        return R.error(BizCodeEnum.TO_MANY_REQUEST.getCode(), BizCodeEnum.TO_MANY_REQUEST.getMessage());
    }
}
